package cn.hwh.springframework.beans.factory.support;

import cn.hwh.springframework.beans.BeansException;
import cn.hwh.springframework.core.io.Resource;
import cn.hwh.springframework.core.io.ResourceLoader;

/**
 * @author wenhao hu
 * @title: BeanDefinitionReader
 * @projectName mini-spring
 * @description: TODO
 * @date 2022/1/2514:27
 */
public interface BeanDefinitionReader {
    //提供给后面三个加载Bean的方法，用于加载和注册Bean
    BeanDefinitionRegistry getRegistry();

    ResourceLoader getResourceLoader();

    void loadBeanDefinitions(Resource resource) throws BeansException;

    void loadBeanDefinitions(Resource ...resources) throws BeansException;

    void loadBeanDefinitions(String location) throws BeansException;

    void loadBeanDefinitions(String ...location) throws BeansException;
}
